﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;

    public class Tool
    {
        public static bool FloatToBool(float value)
        {

            if (value > 0)
            {
                return true;
            }
            else if (value < 0)
            {

                return false;
            }
            return false;
        }
        public static float BoolToFloat(bool value)
        {
            if (value)
            {
                return 1;
            }
            else
            {
                return -1;
            }
        }

    public static List<string> JoyAxisTolist()
    {
        List<string> list = new List<string>();
        foreach (var e in Enum.GetValues(typeof(JoyAxis)))//枚举转List
        {
            list.Add(e.ToString());
        }
        return list;
    }


}
